Skip to content

[VL] tools/workload/tpch: Close sql files to avoid resources leak#10785

Merged
jinchengchenghh merged 2 commits intoapache:mainfrom
xinghuayu007:my/optimize_tpch
Oct 12, 2025
Merged

[VL] tools/workload/tpch: Close sql files to avoid resources leak#10785
jinchengchenghh merged 2 commits intoapache:mainfrom
xinghuayu007:my/optimize_tpch

Conversation

@xinghuayu007
Copy link
Contributor

What changes are proposed in this pull request?

SQL files is not close after running, which maybe cause resources leak.
This patch also prints the results in lines for statistics convenience.

How was this patch tested?

@github-actions github-actions bot added the TOOLS label Sep 23, 2025
@zhztheplayer zhztheplayer changed the title [GLUTEN] Close sql files to avoid resources leak [VL] tools/workload/tpch: Close sql files to avoid resources leak Sep 23, 2025
println(fileContents)
time{spark.sql(fileContents).collectAsList()}
//spark.sql(fileContents).explain
val fileContents = {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please don't change the function time, just close the file

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. I mean to print the final results for statistics without any middle results. Maybe the middle results is important for other situations.

@jinchengchenghh jinchengchenghh merged commit 0f88d2a into apache:main Oct 12, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants